package org.jeecg.modules.complain.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.jeecg.modules.complain.entity.RepairConfig;
import org.jeecg.modules.system.entity.SysDepartPosition;
import org.jeecg.modules.system.entity.SysPosition;
import org.jeecg.modules.system.entity.SysUserPosition;

import java.util.List;

/**
 * @Description: 报修基础配置
 * @Author: jeecg-boot
 * @Date:   2019-07-29
 * @Version: V1.0
 */
public interface RepairConfigMapper extends BaseMapper<RepairConfig> {

    List<SysPosition> selectByDepartId(@Param("departId") String departId, @Param("codeList") List<String> codeList, @Param("id") String id);
    String selectByPositionId(@Param("idList") List id);
   RepairConfig selectConfigByDepartId(@Param("departId") String departId);
    void delet(@Param("departId") String departId);
    List<RepairConfig>  findByDepartId(@Param("departId") String departId);
    List<SysUserPosition> getAllPostionUser(@Param("departId") String departId, @Param("codeList") List codeList, @Param("id") String userId);
    String selectDepartId(@Param("departId") String departId);

    List<RepairConfig> selectAllRepairConfig(@Param("sysDepartPositionList") List<SysDepartPosition> sysDepartPositionList);
    @Select("select depart_id from base_project where id = #{projectId}")
    String getDepartIdByProjectId(@Param("projectId") String projectId);
}
